object DataModule1: TDataModule1
  OldCreateOrder = False
  Height = 428
  Width = 783
  object dsCity: TDataSource
    AutoEdit = False
    DataSet = fbCity
    Left = 144
    Top = 120
  end
  object dsState: TDataSource
    AutoEdit = False
    DataSet = fbState
    Left = 88
    Top = 120
  end
  object dsCountry: TDataSource
    AutoEdit = False
    DataSet = fbCountry
    Left = 32
    Top = 120
  end
  object dsCustomers: TDataSource
    AutoEdit = False
    DataSet = fbCustomers
    Left = 200
    Top = 120
  end
  object fbCountry: TIBTable
    Database = IBDatabase1
    Transaction = IBTransaction1
    AfterClose = fbCountryAfterClose
    CachedUpdates = True
    FieldDefs = <
      item
        Name = 'ID'
        DataType = ftInteger
      end
      item
        Name = 'ABBRIVIATION'
        Attributes = [faRequired]
        DataType = ftString
        Size = 4
      end
      item
        Name = 'COUNTRY'
        Attributes = [faRequired]
        DataType = ftString
        Size = 255
      end>
    IndexDefs = <
      item
        Name = 'UNQ1_COUNTRY'
        Fields = 'ABBRIVIATION;COUNTRY'
        Options = [ixUnique]
      end
      item
        Name = 'PK_COUNTRY'
        Fields = 'ID'
        Options = [ixUnique]
      end
      item
        Name = 'UNQ2_COUNTRY'
        Fields = 'ABBRIVIATION'
        Options = [ixUnique]
      end>
    StoreDefs = True
    TableName = 'COUNTRY'
    Left = 32
    Top = 72
  end
  object IBDatabase1: TIBDatabase
    DatabaseName = 'D:\InvoiceManagerLensworks\invoicemanager.fdb'
    Params.Strings = (
      'user_name=sysdba'
      'password=masterkey')
    LoginPrompt = False
    DefaultTransaction = IBTransaction1
    ServerType = 'IBServer'
    TraceFlags = [tfQExecute, tfError, tfStmt, tfConnect, tfTransact]
    Left = 32
    Top = 16
  end
  object IBTransaction1: TIBTransaction
    DefaultDatabase = IBDatabase1
    Left = 112
    Top = 16
  end
  object IBSQLMonitor1: TIBSQLMonitor
    OnSQL = IBSQLMonitor1SQL
    TraceFlags = [tfQExecute, tfError, tfStmt, tfConnect, tfTransact]
    Left = 192
    Top = 16
  end
  object fbCustomers: TIBTable
    Database = IBDatabase1
    Transaction = IBTransaction1
    AfterClose = fbCustomersAfterClose
    CachedUpdates = True
    FieldDefs = <
      item
        Name = 'ID'
        DataType = ftInteger
      end
      item
        Name = 'COMPANY_NAME'
        Attributes = [faRequired]
        DataType = ftWideString
        Size = 255
      end
      item
        Name = 'ADDRESS'
        DataType = ftWideString
        Size = 255
      end
      item
        Name = 'POSTCODE'
        DataType = ftWideString
        Size = 5
      end
      item
        Name = 'CITY'
        DataType = ftWideString
        Size = 50
      end
      item
        Name = 'STATE'
        DataType = ftWideString
        Size = 50
      end
      item
        Name = 'COUNTRY'
        DataType = ftWideString
        Size = 30
      end
      item
        Name = 'COMPANY_TEL'
        DataType = ftWideString
        Size = 50
      end
      item
        Name = 'COMPANY_FAX'
        DataType = ftWideString
        Size = 50
      end
      item
        Name = 'COMPANY_EMAIL'
        DataType = ftWideString
        Size = 100
      end
      item
        Name = 'CONTACT_NAME'
        DataType = ftWideString
        Size = 255
      end
      item
        Name = 'CONTACT_EMAIL'
        DataType = ftWideString
        Size = 100
      end
      item
        Name = 'CONTACT_TEL'
        DataType = ftWideString
        Size = 50
      end>
    IndexDefs = <
      item
        Name = 'PK_CUSTOMERS'
        Fields = 'ID'
        Options = [ixUnique]
      end
      item
        Name = 'UNQ1_CUSTOMERS'
        Fields = 'COMPANY_NAME'
        Options = [ixUnique]
      end>
    IndexFieldNames = 'COMPANY_NAME'
    StoreDefs = True
    TableName = 'CUSTOMERS'
    Left = 200
    Top = 72
  end
  object fbState: TIBTable
    Database = IBDatabase1
    Transaction = IBTransaction1
    AfterClose = fbStateAfterClose
    CachedUpdates = True
    FieldDefs = <
      item
        Name = 'ID'
        DataType = ftInteger
      end
      item
        Name = 'ABBRIVIATION'
        Attributes = [faRequired]
        DataType = ftString
        Size = 4
      end
      item
        Name = 'STATE'
        Attributes = [faRequired]
        DataType = ftString
        Size = 255
      end
      item
        Name = 'COUNTRY_ABBRIVIATION'
        Attributes = [faRequired]
        DataType = ftString
        Size = 4
      end>
    IndexDefs = <
      item
        Name = 'PK_STATE'
        Fields = 'ID'
        Options = [ixUnique]
      end
      item
        Name = 'UNQ1_STATE'
        Fields = 'ABBRIVIATION;STATE'
        Options = [ixUnique]
      end
      item
        Name = 'UNQ2_STATE'
        Fields = 'ABBRIVIATION'
        Options = [ixUnique]
      end>
    IndexFieldNames = 'COUNTRY_ABBRIVIATION'
    MasterFields = 'ABBRIVIATION'
    MasterSource = dsCountry
    StoreDefs = True
    TableName = 'STATE'
    Left = 88
    Top = 72
  end
  object fbCity: TIBTable
    Database = IBDatabase1
    Transaction = IBTransaction1
    AfterClose = fbCityAfterClose
    CachedUpdates = True
    FieldDefs = <
      item
        Name = 'ID'
        DataType = ftInteger
      end
      item
        Name = 'CITY'
        Attributes = [faRequired]
        DataType = ftString
        Size = 255
      end
      item
        Name = 'STATE_ABBRIVIATION'
        Attributes = [faRequired]
        DataType = ftString
        Size = 4
      end
      item
        Name = 'COUNTRY_ABBRIVIATION'
        Attributes = [faRequired]
        DataType = ftString
        Size = 4
      end>
    IndexDefs = <
      item
        Name = 'UNQ1_CITY'
        Fields = 'CITY;STATE_ABBRIVIATION;COUNTRY_ABBRIVIATION'
        Options = [ixUnique]
      end
      item
        Name = 'PK_CITY_STATE'
        Fields = 'ID'
        Options = [ixUnique]
      end>
    IndexFieldNames = 'STATE_ABBRIVIATION;COUNTRY_ABBRIVIATION'
    MasterFields = 'ABBRIVIATION;COUNTRY_ABBRIVIATION'
    MasterSource = dsState
    StoreDefs = True
    TableName = 'CITY'
    Left = 144
    Top = 72
  end
  object fbInvoice: TIBTable
    Database = IBDatabase1
    Transaction = IBTransaction1
    AfterClose = fbInvoiceAfterClose
    FieldDefs = <
      item
        Name = 'ID'
        DataType = ftInteger
      end
      item
        Name = 'INVOICE_NO'
        Attributes = [faRequired]
        DataType = ftWideString
        Size = 9
      end
      item
        Name = 'INVOICE_DUE_DATE'
        Attributes = [faRequired]
        DataType = ftDate
      end
      item
        Name = 'INVOICE_DATE'
        Attributes = [faRequired]
        DataType = ftDate
      end
      item
        Name = 'CUSTOMER_ID'
        Attributes = [faRequired]
        DataType = ftInteger
      end
      item
        Name = 'FOR_PRODUCT'
        DataType = ftWideString
        Size = 255
      end
      item
        Name = 'FOR'
        Attributes = [faRequired]
        DataType = ftWideString
        Size = 255
      end
      item
        Name = 'TOTAL_AMOUNT'
        Attributes = [faRequired]
        DataType = ftBCD
        Precision = 9
        Size = 2
      end
      item
        Name = 'DATE_OF_SHOOT'
        DataType = ftDate
      end
      item
        Name = 'PAID'
        Attributes = [faFixed]
        DataType = ftWideString
        Size = 1
      end
      item
        Name = 'AMOUNT_RECEIVED'
        DataType = ftBCD
        Precision = 9
        Size = 2
      end
      item
        Name = 'PAYMENT_TYPE'
        DataType = ftWideString
        Size = 20
      end
      item
        Name = 'PAYMENT_RECEIVED_DATE'
        DataType = ftDate
      end
      item
        Name = 'PAYMENT_REFERENCE'
        DataType = ftWideString
        Size = 255
      end
      item
        Name = 'PAYMENT_DETAILS'
        DataType = ftWideString
        Size = 255
      end
      item
        Name = 'REMARK'
        DataType = ftWideString
        Size = 1000
      end
      item
        Name = 'JOBSHEET_NO'
        DataType = ftWideString
        Size = 9
      end
      item
        Name = 'PERSON_IN_CHARGE'
        DataType = ftWideString
        Size = 100
      end
      item
        Name = 'PUBLISH_ON'
        DataType = ftWideString
        Size = 100
      end
      item
        Name = 'PHOTOGRAPHER1_ID'
        Attributes = [faRequired]
        DataType = ftInteger
      end
      item
        Name = 'PHOTOGRAPHER2_ID'
        DataType = ftInteger
      end
      item
        Name = 'CREATE_DATE'
        DataType = ftDateTime
      end
      item
        Name = 'UPDATE_DATE'
        DataType = ftDateTime
      end>
    IndexDefs = <
      item
        Name = 'FK_INVOICE_2'
        Fields = 'CUSTOMER_ID'
      end
      item
        Name = 'PK_INVOICE'
        Fields = 'ID'
        Options = [ixUnique]
      end
      item
        Name = 'UNQ1_INVOICE'
        Fields = 'INVOICE_NO'
        Options = [ixUnique]
      end
      item
        Name = 'UNQ2_INVOICE'
        Fields = 'JOBSHEET_NO'
        Options = [ixUnique]
      end>
    StoreDefs = True
    TableName = 'INVOICE'
    Left = 491
    Top = 72
  end
  object fbInvoiceDetails: TIBTable
    Database = IBDatabase1
    Transaction = IBTransaction1
    AfterClose = fbInvoiceDetailsAfterClose
    FieldDefs = <
      item
        Name = 'ID'
        DataType = ftInteger
      end
      item
        Name = 'INVOICE_NO'
        Attributes = [faRequired]
        DataType = ftWideString
        Size = 9
      end
      item
        Name = 'DESCRIPTION'
        Attributes = [faRequired]
        DataType = ftWideString
        Size = 255
      end
      item
        Name = 'AMOUNT'
        Attributes = [faRequired]
        DataType = ftFloat
      end
      item
        Name = 'DESCRIPTION_RTF'
        DataType = ftBlob
        Size = 8
      end
      item
        Name = 'FOC_DI'
        Attributes = [faFixed]
        DataType = ftWideString
        Size = 1
      end
      item
        Name = 'CREATE_DATE'
        DataType = ftDateTime
      end
      item
        Name = 'UPDATE_DATE'
        DataType = ftDateTime
      end>
    IndexDefs = <
      item
        Name = 'PK_INVOICE_DETAILS'
        Fields = 'ID'
        Options = [ixUnique]
      end
      item
        Name = 'FK_INVOICE_DETAILS_1'
        Fields = 'INVOICE_NO'
      end>
    IndexFieldNames = 'INVOICE_NO'
    MasterFields = 'INVOICE_NO'
    MasterSource = dsInvoiceList
    StoreDefs = True
    TableName = 'INVOICE_DETAILS'
    Left = 32
    Top = 288
  end
  object dsInvoice: TDataSource
    DataSet = fbInvoice
    Left = 491
    Top = 120
  end
  object dsInvoiceDetails: TDataSource
    DataSet = fbInvoiceDetails
    Left = 32
    Top = 336
  end
  object qryInvoiceList: TIBQuery
    Database = IBDatabase1
    Transaction = IBTransaction1
    SQL.Strings = (
      'Select'
      '  INVOICE.ID,'
      '  INVOICE.INVOICE_NO,'
      '  INVOICE.INVOICE_DATE,'
      '  INVOICE.INVOICE_DUE_DATE,'
      '  CUSTOMERS.COMPANY_NAME,'
      '  INVOICE."FOR",'
      '  INVOICE."PO_NO",'
      '  INVOICE.FOR_PRODUCT,'
      '  INVOICE.TOTAL_AMOUNT,'
      '  INVOICE.CREATE_DATE,'
      '  INVOICE.UPDATE_DATE,'
      '  INVOICE.DATE_OF_SHOOT,'
      '  INVOICE.PAID,'
      '  INVOICE.AMOUNT_RECEIVED,'
      '  INVOICE.PAYMENT_TYPE,'
      '  INVOICE.PAYMENT_REFERENCE,'
      '  INVOICE.PAYMENT_RECEIVED_DATE,'
      '  INVOICE.PAYMENT_DETAILS,'
      '  INVOICE.JOBSHEET_NO,'
      '  INVOICE.PERSON_IN_CHARGE,'
      '  INVOICE.PHOTOGRAPHER1_ID,'
      '  INVOICE.PHOTOGRAPHER2_ID,'
      '  INVOICE.REMARK,'
      '  INVOICE.PUBLISH_ON'
      'From'
      '  CUSTOMERS Inner Join'
      '  INVOICE On INVOICE.CUSTOMER_ID = CUSTOMERS.ID'
      'ORDER BY INVOICE.INVOICE_NO')
    Left = 32
    Top = 192
  end
  object dsInvoiceList: TDataSource
    DataSet = qryInvoiceList
    Left = 32
    Top = 240
  end
  object qryPrintInvoice: TIBQuery
    Database = IBDatabase1
    Transaction = IBTransaction1
    SQL.Strings = (
      'Select'
      '  INVOICE.INVOICE_NO,'
      '  INVOICE.PO_NO,'
      '  INVOICE.INVOICE_DATE,'
      '  INVOICE.DATE_OF_SHOOT,'
      '  INVOICE."FOR",'
      '  INVOICE.FOR_PRODUCT,'
      '  INVOICE.TOTAL_AMOUNT,'
      '  INVOICE.PERSON_IN_CHARGE,'
      '  INVOICE.PUBLISH_ON,'
      '  INVOICE.JOBSHEET_NO,'
      '  CUSTOMERS.COMPANY_NAME,'
      '  CUSTOMERS.ADDRESS,'
      '  CUSTOMERS.POSTCODE,'
      '  CUSTOMERS.CITY,'
      '  CUSTOMERS.STATE,'
      '  CUSTOMERS.COUNTRY,'
      '  CUSTOMERS.COMPANY_TEL,'
      '  CUSTOMERS.COMPANY_FAX,'
      '  CUSTOMERS.COMPANY_EMAIL,'
      '  CUSTOMERS.CONTACT_NAME,'
      '  CUSTOMERS.CONTACT_EMAIL,'
      '  CUSTOMERS.CONTACT_TEL'
      'From'
      '  INVOICE Inner Join'
      '  CUSTOMERS On INVOICE.CUSTOMER_ID = CUSTOMERS.ID'
      '')
    Left = 136
    Top = 192
  end
  object fbPrintInvoiceDetails: TIBTable
    Database = IBDatabase1
    Transaction = IBTransaction1
    FieldDefs = <
      item
        Name = 'ID'
        DataType = ftInteger
      end
      item
        Name = 'INVOICE_NO'
        Attributes = [faRequired]
        DataType = ftString
        Size = 9
      end
      item
        Name = 'DESCRIPTION'
        Attributes = [faRequired]
        DataType = ftString
        Size = 500
      end
      item
        Name = 'AMOUNT'
        Attributes = [faRequired]
        DataType = ftFloat
      end
      item
        Name = 'DESCRIPTION_RTF'
        DataType = ftBlob
      end
      item
        Name = 'FOC_DI'
        DataType = ftString
        Size = 1
      end
      item
        Name = 'CREATE_DATE'
        DataType = ftDateTime
      end
      item
        Name = 'UPDATE_DATE'
        DataType = ftDateTime
      end>
    IndexDefs = <
      item
        Name = 'PK_INVOICE_DETAILS'
        Fields = 'ID'
        Options = [ixUnique]
      end
      item
        Name = 'FK_INVOICE_DETAILS_1'
        Fields = 'INVOICE_NO'
      end>
    IndexFieldNames = 'INVOICE_NO'
    MasterFields = 'INVOICE_NO'
    MasterSource = dsInvoiceMaster
    StoreDefs = True
    TableName = 'INVOICE_DETAILS'
    Left = 136
    Top = 288
  end
  object dsInvoiceMaster: TDataSource
    DataSet = qryPrintInvoice
    Left = 136
    Top = 240
  end
  object DataSource1: TDataSource
    DataSet = fbPrintInvoiceDetails
    Left = 136
    Top = 336
  end
  object fbMarriageStatus: TIBTable
    Database = IBDatabase1
    Transaction = IBTransaction1
    FieldDefs = <
      item
        Name = 'ID'
        DataType = ftInteger
      end
      item
        Name = 'NAME'
        Attributes = [faRequired]
        DataType = ftWideString
        Size = 255
      end
      item
        Name = 'DSC'
        DataType = ftWideString
        Size = 255
      end>
    IndexDefs = <
      item
        Name = 'UNQ1_MARRIAGE_STATUS'
        Fields = 'NAME'
        Options = [ixUnique]
      end
      item
        Name = 'PK_MARRIAGE_STATUS'
        Fields = 'ID'
        Options = [ixUnique]
      end>
    StoreDefs = True
    TableName = 'MARRIAGE_STATUS'
    Left = 248
    Top = 192
  end
  object fbJobPosition: TIBTable
    Database = IBDatabase1
    Transaction = IBTransaction1
    FieldDefs = <
      item
        Name = 'ID'
        DataType = ftInteger
      end
      item
        Name = 'NAME'
        Attributes = [faRequired]
        DataType = ftWideString
        Size = 100
      end
      item
        Name = 'DSC'
        DataType = ftWideString
        Size = 255
      end>
    IndexDefs = <
      item
        Name = 'PK_JOB_POSITION'
        Fields = 'ID'
        Options = [ixUnique]
      end
      item
        Name = 'UNQ1_JOB_POSITION'
        Fields = 'NAME'
        Options = [ixUnique]
      end>
    StoreDefs = True
    TableName = 'JOB_POSITION'
    Left = 336
    Top = 192
  end
  object fbEmployee: TIBTable
    Database = IBDatabase1
    Transaction = IBTransaction1
    AfterClose = fbEmployeeAfterClose
    FieldDefs = <
      item
        Name = 'ID'
        DataType = ftInteger
      end
      item
        Name = 'NAME'
        DataType = ftString
        Size = 90
      end
      item
        Name = 'FIRST_NAME'
        Attributes = [faRequired]
        DataType = ftString
        Size = 30
      end
      item
        Name = 'LAST_NAME'
        Attributes = [faRequired]
        DataType = ftString
        Size = 60
      end
      item
        Name = 'GENDER'
        Attributes = [faRequired]
        DataType = ftString
        Size = 1
      end
      item
        Name = 'DOB'
        Attributes = [faRequired]
        DataType = ftDate
      end
      item
        Name = 'START_SERVICE_DATE'
        Attributes = [faRequired]
        DataType = ftDate
      end
      item
        Name = 'POSITION'
        DataType = ftString
        Size = 100
      end
      item
        Name = 'BASE_PAY'
        Attributes = [faRequired]
        DataType = ftBCD
        Precision = 18
        Size = 2
      end
      item
        Name = 'MARRIAGE_STATUS'
        DataType = ftString
        Size = 20
      end
      item
        Name = 'IC_NUMBER'
        Attributes = [faRequired]
        DataType = ftString
        Size = 19
      end
      item
        Name = 'PASSPORT_NUMBER'
        DataType = ftString
        Size = 20
      end
      item
        Name = 'EPF'
        DataType = ftString
        Size = 1
      end
      item
        Name = 'SOCSO'
        DataType = ftString
        Size = 1
      end
      item
        Name = 'REMARK'
        DataType = ftString
        Size = 1000
      end
      item
        Name = 'CREATE_DATE'
        DataType = ftDateTime
      end
      item
        Name = 'UPDATE_DATE'
        DataType = ftDateTime
      end>
    IndexDefs = <
      item
        Name = 'PK_EMPLOYEE'
        Fields = 'ID'
        Options = [ixUnique]
      end
      item
        Name = 'UNQ1_EMPLOYEE'
        Fields = 'IC_NUMBER'
        Options = [ixUnique]
      end>
    StoreDefs = True
    TableName = 'EMPLOYEE'
    Left = 560
    Top = 72
  end
  object dsMarriageStatus: TDataSource
    DataSet = fbMarriageStatus
    Left = 248
    Top = 240
  end
  object dsJobPosition: TDataSource
    DataSet = fbJobPosition
    Left = 336
    Top = 240
  end
  object dsEmployee: TDataSource
    DataSet = fbEmployee
    Left = 560
    Top = 120
  end
  object qrySQL: TIBQuery
    Database = IBDatabase1
    Transaction = IBTransaction1
    Left = 483
    Top = 16
  end
  object qryEmployeeSalary: TIBQuery
    Database = IBDatabase1
    Transaction = IBTransaction1
    SQL.Strings = (
      'SELECT EMPLOYEE.ID, '
      'EMPLOYEE.NAME, '
      'EMPLOYEE.BASE_PAY, '
      'EMPLOYEE.IC_NUMBER, '
      'EMPLOYEE."POSITION", '
      'EMPLOYEE."EPF", '
      'EMPLOYEE."SOCSO", '
      'PAY_SALARY.ID as PAY_ID, '
      'PAY_SALARY."YEAR", '
      'PAY_SALARY."MONTH", '
      'PAY_SALARY.EPF_EMPLOYEE, '
      'PAY_SALARY.EPF_EMPLOYER, '
      'PAY_SALARY.SOCSO_EMPLOYEE, '
      'PAY_SALARY.SOCSO_EMPLOYER, '
      'PAY_SALARY.ADVANCED_PAY, '
      'PAY_SALARY.ALLOWANCE_PAY, '
      'PAY_SALARY.PCB, '
      'PAY_SALARY.NET_PAY, '
      'PAY_SALARY.WORKING_DAYS, '
      'PAY_SALARY.REMARK'
      
        'FROM EMPLOYEE INNER JOIN PAY_SALARY on EMPLOYEE.ID = PAY_SALARY.' +
        'EMPLOYEE_ID'
      'WHERE EMPLOYEE.ID > 0'
      'ORDER BY PAY_SALARY."YEAR", PAY_SALARY."MONTH", EMPLOYEE.NAME')
    Left = 424
    Top = 192
  end
  object dsSalary: TDataSource
    DataSet = qryEmployeeSalary
    Left = 424
    Top = 240
  end
  object fbConfig: TIBTable
    Database = IBDatabase1
    Transaction = IBTransaction1
    AfterClose = fbConfigAfterClose
    FieldDefs = <
      item
        Name = 'COMPANY_ID'
        DataType = ftString
        Size = 4
      end
      item
        Name = 'COMPANY_NAME'
        DataType = ftString
        Size = 255
      end
      item
        Name = 'REGISTER_NO'
        DataType = ftString
        Size = 20
      end
      item
        Name = 'ADDRESS'
        DataType = ftString
        Size = 100
      end
      item
        Name = 'ADDRESS2'
        DataType = ftString
        Size = 100
      end
      item
        Name = 'CITY'
        DataType = ftString
        Size = 50
      end
      item
        Name = 'STATE'
        DataType = ftString
        Size = 50
      end
      item
        Name = 'POSTCODE'
        DataType = ftString
        Size = 7
      end
      item
        Name = 'COUNTRY'
        DataType = ftString
        Size = 50
      end
      item
        Name = 'TEL'
        DataType = ftString
        Size = 50
      end
      item
        Name = 'FAX'
        DataType = ftString
        Size = 50
      end
      item
        Name = 'WEBSITE'
        DataType = ftString
        Size = 100
      end
      item
        Name = 'EMAIL'
        DataType = ftString
        Size = 100
      end
      item
        Name = 'LAST_PV_NO'
        DataType = ftInteger
      end
      item
        Name = 'LAST_INVOICE_NO'
        DataType = ftInteger
      end
      item
        Name = 'INVOICE_PREFIX'
        DataType = ftString
        Size = 4
      end
      item
        Name = 'INVOICE_NO_LENGTH'
        DataType = ftInteger
      end
      item
        Name = 'PV_PREFIX'
        DataType = ftString
        Size = 4
      end
      item
        Name = 'PV_NO_LENGTH'
        DataType = ftInteger
      end
      item
        Name = 'INVOICE_PAY_TERM'
        Attributes = [faRequired]
        DataType = ftInteger
      end
      item
        Name = 'EPF_PER_EMPLOYEE'
        DataType = ftInteger
      end
      item
        Name = 'EPF_PER_EMPLOYER'
        DataType = ftInteger
      end
      item
        Name = 'WORKINGDAYS'
        DataType = ftInteger
      end
      item
        Name = 'UPDATE_DATE'
        DataType = ftDateTime
      end>
    StoreDefs = True
    TableName = 'CONFIG'
    Left = 331
    Top = 16
  end
  object fbPaymentType: TIBTable
    Database = IBDatabase1
    Transaction = IBTransaction1
    AfterClose = fbPaymentTypeAfterClose
    FieldDefs = <
      item
        Name = 'ID'
        DataType = ftInteger
      end
      item
        Name = 'NAME'
        Attributes = [faRequired]
        DataType = ftWideString
        Size = 100
      end
      item
        Name = 'DSC'
        DataType = ftWideString
        Size = 255
      end>
    IndexDefs = <
      item
        Name = 'PK_PAYMENT_TYPE'
        Fields = 'ID'
        Options = [ixUnique]
      end
      item
        Name = 'UNQ1_PAYMENT_TYPE'
        Fields = 'NAME'
        Options = [ixUnique]
      end>
    IndexFieldNames = 'NAME'
    StoreDefs = True
    TableName = 'PAYMENT_TYPE'
    Left = 520
    Top = 192
  end
  object dsPaymentType: TDataSource
    DataSet = fbPaymentType
    Left = 520
    Top = 240
  end
  object dsProducts: TDataSource
    DataSet = fbProducts
    Left = 272
    Top = 120
  end
  object fbProducts: TIBTable
    Database = IBDatabase1
    Transaction = IBTransaction1
    AfterClose = fbProductsAfterClose
    FieldDefs = <
      item
        Name = 'ID'
        Attributes = [faRequired]
        DataType = ftInteger
      end
      item
        Name = 'CUSTOMER_ID'
        Attributes = [faRequired]
        DataType = ftInteger
      end
      item
        Name = 'PRODUCT_NAME'
        Attributes = [faRequired]
        DataType = ftWideString
        Size = 50
      end>
    IndexDefs = <
      item
        Name = 'PK_CUSTOMER_PRODUCT'
        Fields = 'ID'
        Options = [ixUnique]
      end
      item
        Name = 'FK_CUSTOMER_PRODUCT_1'
        Fields = 'CUSTOMER_ID'
      end
      item
        Name = 'UNQ1_CUSTOMER_PRODUCT'
        Fields = 'PRODUCT_NAME'
        Options = [ixUnique]
      end>
    IndexFieldNames = 'CUSTOMER_ID'
    MasterFields = 'ID'
    MasterSource = dsCustomers
    StoreDefs = True
    TableName = 'CUSTOMER_PRODUCT'
    Left = 272
    Top = 72
  end
  object fbExpenses: TIBTable
    Database = IBDatabase1
    Transaction = IBTransaction1
    FieldDefs = <
      item
        Name = 'ID'
        DataType = ftInteger
      end
      item
        Name = 'CATEGORY_ID'
        Attributes = [faRequired]
        DataType = ftInteger
      end
      item
        Name = 'NAME'
        Attributes = [faRequired]
        DataType = ftWideString
        Size = 255
      end
      item
        Name = 'SUPPLIER_ID'
        DataType = ftInteger
      end
      item
        Name = 'PERIOD_YEAR'
        Attributes = [faRequired]
        DataType = ftWideString
        Size = 4
      end
      item
        Name = 'PERIOD_MONTH'
        Attributes = [faRequired]
        DataType = ftWideString
        Size = 2
      end
      item
        Name = 'AMOUNT'
        Attributes = [faRequired]
        DataType = ftBCD
        Precision = 18
        Size = 2
      end
      item
        Name = 'REFERENCE'
        DataType = ftWideString
        Size = 255
      end
      item
        Name = 'DUE_DATE'
        Attributes = [faRequired]
        DataType = ftDate
      end
      item
        Name = 'PAID'
        Attributes = [faFixed]
        DataType = ftWideString
        Size = 1
      end
      item
        Name = 'PAYMENT_DATE'
        DataType = ftDate
      end
      item
        Name = 'PAYMENT_TYPE'
        DataType = ftWideString
        Size = 10
      end
      item
        Name = 'PAYMENT_REFERENCE'
        DataType = ftWideString
        Size = 255
      end
      item
        Name = 'PAID_AMOUNT'
        DataType = ftBCD
        Precision = 18
        Size = 2
      end
      item
        Name = 'BILLABLE'
        Attributes = [faRequired, faFixed]
        DataType = ftWideString
        Size = 1
      end
      item
        Name = 'REMARK'
        DataType = ftWideString
        Size = 255
      end
      item
        Name = 'CREATE_DATE'
        DataType = ftDateTime
      end
      item
        Name = 'UPDATE_DATE'
        DataType = ftDateTime
      end>
    IndexDefs = <
      item
        Name = 'PK_EXPENSES'
        Fields = 'ID'
        Options = [ixUnique]
      end
      item
        Name = 'FK_EXPENSES_1'
        Fields = 'CATEGORY_ID'
      end
      item
        Name = 'FK_EXPENSES_2'
        Fields = 'SUPPLIER_ID'
      end>
    IndexFieldNames = 'CATEGORY_ID'
    MasterFields = 'ID'
    MasterSource = dsExpenseCategory
    StoreDefs = True
    TableName = 'EXPENSES'
    Left = 424
    Top = 288
  end
  object dsExpenses: TDataSource
    DataSet = fbExpenses
    Left = 424
    Top = 336
  end
  object fbExpenseCategory: TIBTable
    Database = IBDatabase1
    Transaction = IBTransaction1
    FieldDefs = <
      item
        Name = 'ID'
        DataType = ftInteger
      end
      item
        Name = 'NAME'
        Attributes = [faRequired]
        DataType = ftWideString
        Size = 100
      end
      item
        Name = 'DSC'
        DataType = ftWideString
        Size = 255
      end>
    IndexDefs = <
      item
        Name = 'PK_EXPENSE_CATEGORY'
        Fields = 'ID'
        Options = [ixUnique]
      end
      item
        Name = 'UNQ1_EXPENSE_CATEGORY'
        Fields = 'NAME'
        Options = [ixUnique]
      end>
    StoreDefs = True
    TableName = 'EXPENSE_CATEGORY'
    Left = 336
    Top = 288
  end
  object dsExpenseCategory: TDataSource
    DataSet = fbExpenseCategory
    Left = 336
    Top = 336
  end
  object dsSupplier: TDataSource
    DataSet = fbSupplier
    Left = 248
    Top = 336
  end
  object fbSupplier: TIBTable
    Database = IBDatabase1
    Transaction = IBTransaction1
    FieldDefs = <
      item
        Name = 'ID'
        DataType = ftInteger
      end
      item
        Name = 'COMPANY_NAME'
        Attributes = [faRequired]
        DataType = ftString
        Size = 100
      end
      item
        Name = 'ADDRESS'
        DataType = ftString
        Size = 255
      end
      item
        Name = 'POSTCODE'
        DataType = ftString
        Size = 5
      end
      item
        Name = 'CITY'
        DataType = ftString
        Size = 50
      end
      item
        Name = 'STATE'
        DataType = ftString
        Size = 50
      end
      item
        Name = 'COUNTRY'
        DataType = ftString
        Size = 30
      end
      item
        Name = 'COMPANY_TEL'
        DataType = ftString
        Size = 50
      end
      item
        Name = 'COMPANY_FAX'
        DataType = ftString
        Size = 50
      end
      item
        Name = 'COMPANY_EMAIL'
        DataType = ftString
        Size = 100
      end
      item
        Name = 'CONTACT_NAME'
        DataType = ftString
        Size = 255
      end
      item
        Name = 'CONTACT_EMAIL'
        DataType = ftString
        Size = 100
      end
      item
        Name = 'CONTACT_TEL'
        DataType = ftString
        Size = 50
      end>
    IndexDefs = <
      item
        Name = 'PK_SUPPLIER'
        Fields = 'ID'
        Options = [ixUnique]
      end
      item
        Name = 'UNQ1_SUPPLIER'
        Fields = 'COMPANY_NAME'
        Options = [ixUnique]
      end>
    StoreDefs = True
    TableName = 'SUPPLIER'
    Left = 248
    Top = 288
  end
  object qryExpenses: TIBQuery
    Database = IBDatabase1
    Transaction = IBTransaction1
    SQL.Strings = (
      'Select'
      '  EXPENSE_CATEGORY.NAME As CATEGORY_NAME,'
      '  EXPENSES.*'
      'From'
      '  EXPENSES Inner Join'
      '  EXPENSE_CATEGORY On EXPENSES.CATEGORY_ID = EXPENSE_CATEGORY.ID'
      'Order By'
      '  EXPENSE_CATEGORY.NAME')
    Left = 504
    Top = 288
  end
  object dsExpenses2: TDataSource
    DataSet = qryExpenses
    Left = 504
    Top = 336
  end
  object dsPhotographer1: TDataSource
    DataSet = fbEmployee1
    Left = 632
    Top = 120
  end
  object dsPhotographer2: TDataSource
    DataSet = fbEmployee2
    Left = 696
    Top = 120
  end
  object fbEmployee1: TIBTable
    Database = IBDatabase1
    Transaction = IBTransaction1
    AfterClose = fbEmployee1AfterClose
    FieldDefs = <
      item
        Name = 'ID'
        DataType = ftInteger
      end
      item
        Name = 'NAME'
        DataType = ftString
        Size = 90
      end
      item
        Name = 'FIRST_NAME'
        Attributes = [faRequired]
        DataType = ftString
        Size = 30
      end
      item
        Name = 'LAST_NAME'
        Attributes = [faRequired]
        DataType = ftString
        Size = 60
      end
      item
        Name = 'GENDER'
        Attributes = [faRequired]
        DataType = ftString
        Size = 1
      end
      item
        Name = 'DOB'
        Attributes = [faRequired]
        DataType = ftDate
      end
      item
        Name = 'START_SERVICE_DATE'
        Attributes = [faRequired]
        DataType = ftDate
      end
      item
        Name = 'POSITION'
        DataType = ftString
        Size = 100
      end
      item
        Name = 'BASE_PAY'
        Attributes = [faRequired]
        DataType = ftBCD
        Precision = 18
        Size = 2
      end
      item
        Name = 'MARRIAGE_STATUS'
        DataType = ftString
        Size = 20
      end
      item
        Name = 'IC_NUMBER'
        Attributes = [faRequired]
        DataType = ftString
        Size = 19
      end
      item
        Name = 'PASSPORT_NUMBER'
        DataType = ftString
        Size = 20
      end
      item
        Name = 'EPF'
        DataType = ftString
        Size = 1
      end
      item
        Name = 'SOCSO'
        DataType = ftString
        Size = 1
      end
      item
        Name = 'REMARK'
        DataType = ftString
        Size = 1000
      end
      item
        Name = 'CREATE_DATE'
        DataType = ftDateTime
      end
      item
        Name = 'UPDATE_DATE'
        DataType = ftDateTime
      end>
    IndexDefs = <
      item
        Name = 'PK_EMPLOYEE'
        Fields = 'ID'
        Options = [ixUnique]
      end
      item
        Name = 'UNQ1_EMPLOYEE'
        Fields = 'IC_NUMBER'
        Options = [ixUnique]
      end>
    StoreDefs = True
    TableName = 'EMPLOYEE'
    Left = 632
    Top = 72
  end
  object fbEmployee2: TIBTable
    Database = IBDatabase1
    Transaction = IBTransaction1
    AfterClose = fbEmployee2AfterClose
    FieldDefs = <
      item
        Name = 'ID'
        DataType = ftInteger
      end
      item
        Name = 'NAME'
        DataType = ftString
        Size = 90
      end
      item
        Name = 'FIRST_NAME'
        Attributes = [faRequired]
        DataType = ftString
        Size = 30
      end
      item
        Name = 'LAST_NAME'
        Attributes = [faRequired]
        DataType = ftString
        Size = 60
      end
      item
        Name = 'GENDER'
        Attributes = [faRequired]
        DataType = ftString
        Size = 1
      end
      item
        Name = 'DOB'
        Attributes = [faRequired]
        DataType = ftDate
      end
      item
        Name = 'START_SERVICE_DATE'
        Attributes = [faRequired]
        DataType = ftDate
      end
      item
        Name = 'POSITION'
        DataType = ftString
        Size = 100
      end
      item
        Name = 'BASE_PAY'
        Attributes = [faRequired]
        DataType = ftBCD
        Precision = 18
        Size = 2
      end
      item
        Name = 'MARRIAGE_STATUS'
        DataType = ftString
        Size = 20
      end
      item
        Name = 'IC_NUMBER'
        Attributes = [faRequired]
        DataType = ftString
        Size = 19
      end
      item
        Name = 'PASSPORT_NUMBER'
        DataType = ftString
        Size = 20
      end
      item
        Name = 'EPF'
        DataType = ftString
        Size = 1
      end
      item
        Name = 'SOCSO'
        DataType = ftString
        Size = 1
      end
      item
        Name = 'REMARK'
        DataType = ftString
        Size = 1000
      end
      item
        Name = 'CREATE_DATE'
        DataType = ftDateTime
      end
      item
        Name = 'UPDATE_DATE'
        DataType = ftDateTime
      end>
    IndexDefs = <
      item
        Name = 'PK_EMPLOYEE'
        Fields = 'ID'
        Options = [ixUnique]
      end
      item
        Name = 'UNQ1_EMPLOYEE'
        Fields = 'IC_NUMBER'
        Options = [ixUnique]
      end>
    StoreDefs = True
    TableName = 'EMPLOYEE'
    Left = 696
    Top = 72
  end
  object qryReport: TIBQuery
    Database = IBDatabase1
    Transaction = IBTransaction1
    SQL.Strings = (
      'Select CUSTOMERS.*, INVOICE.INVOICE_NO, '
      'INVOICE.INVOICE_DUE_DATE, INVOICE.TOTAL_AMOUNT,  '
      'INVOICE.DATE_OF_SHOOT, INVOICE."FOR", '
      'INVOICE.PAYMENT_RECEIVED_DATE, INVOICE.PAYMENT_TYPE, '
      'INVOICE.PAYMENT_REFERENCE, INVOICE.AMOUNT_RECEIVED '
      
        'From INVOICE Inner Join CUSTOMERS On INVOICE.CUSTOMER_ID = CUSTO' +
        'MERS.ID '
      
        'Order By CUSTOMERS.COMPANY_NAME, INVOICE.DATE_OF_SHOOT, INVOICE.' +
        'INVOICE_NO')
    Left = 376
    Top = 64
  end
  object fbPartTimeSetting: TIBTable
    Database = IBDatabase1
    Transaction = IBTransaction1
    AfterClose = fbPartTimeSettingAfterClose
    FieldDefs = <
      item
        Name = 'ID'
        Attributes = [faRequired]
        DataType = ftInteger
      end
      item
        Name = 'EMPLOYEE_ID'
        Attributes = [faRequired]
        DataType = ftInteger
      end
      item
        Name = 'SOURCE'
        Attributes = [faRequired]
        DataType = ftWideString
        Size = 50
      end
      item
        Name = 'DESTINATION'
        Attributes = [faRequired]
        DataType = ftWideString
        Size = 50
      end
      item
        Name = 'PERCENTAGE'
        DataType = ftInteger
      end
      item
        Name = 'AMOUNT'
        DataType = ftBCD
        Precision = 18
        Size = 2
      end
      item
        Name = 'REMARK'
        DataType = ftWideString
        Size = 255
      end
      item
        Name = 'CREATE_DATE'
        Attributes = [faRequired]
        DataType = ftDateTime
      end
      item
        Name = 'UPDATE_DATE'
        Attributes = [faRequired]
        DataType = ftDateTime
      end>
    IndexDefs = <
      item
        Name = 'PK_PARTTIME_SETTING'
        Fields = 'ID'
        Options = [ixUnique]
      end
      item
        Name = 'FK_PARTTIME_SETTING_1'
        Fields = 'EMPLOYEE_ID'
      end
      item
        Name = 'UNQ1_PARTTIME_SETTING'
        Fields = 'EMPLOYEE_ID'
        Options = [ixUnique]
      end>
    IndexFieldNames = 'EMPLOYEE_ID'
    MasterFields = 'ID'
    MasterSource = dsEmployee
    StoreDefs = True
    TableName = 'PARTTIME_SETTING'
    Left = 600
    Top = 288
  end
  object dsPartTimeSetting: TDataSource
    DataSet = fbPartTimeSetting
    Left = 600
    Top = 336
  end
  object qryConfig: TIBQuery
    Database = IBDatabase1
    Transaction = IBTransaction1
    SQL.Strings = (
      'select * from Config')
    Left = 376
    Top = 16
  end
  object qryPartTimePayment: TIBQuery
    Database = IBDatabase1
    Transaction = IBTransaction1
    SQL.Strings = (
      'Select'
      '  EMPLOYEE.NAME,'
      '  INVOICE.INVOICE_NO,'
      '  INVOICE.DATE_OF_SHOOT,'
      
        '  INVOICE.TOTAL_AMOUNT * PARTTIME_SETTING.PERCENTAGE / 100 as AM' +
        'OUNT'
      'From'
      '  INVOICE Inner Join'
      
        '  PARTTIME_SETTING On INVOICE.PHOTOGRAPHER1_ID = PARTTIME_SETTIN' +
        'G.EMPLOYEE_ID'
      '  Inner Join'
      '  EMPLOYEE On PARTTIME_SETTING.EMPLOYEE_ID = EMPLOYEE.ID'
      'Order By'
      '  INVOICE.DATE_OF_SHOOT')
    Left = 696
    Top = 288
  end
  object dsPartTimePayment: TDataSource
    DataSet = qryPartTimePayment
    Left = 696
    Top = 336
  end
  object qryPaymentVoucher: TIBQuery
    Database = IBDatabase1
    Transaction = IBTransaction1
    SQL.Strings = (
      'Select'
      '  PAYMENT_VOUCHER.PV_NO,'
      '  PAYMENT_VOUCHER.PAY_FOR,'
      '  SUPPLIER.COMPANY_NAME,'
      '  EMPLOYEE.NAME,'
      '  PAYMENT_VOUCHER.DETAILS,'
      '  PAYMENT_VOUCHER.REMARK,'
      '  PAYMENT_VOUCHER.AMOUNT,'
      '  PAYMENT_VOUCHER.MODIFIED_DATE'
      'From'
      '  PAYMENT_VOUCHER Inner Join'
      
        '  SUPPLIER On PAYMENT_VOUCHER.SUPPLIER_ID = SUPPLIER.ID Inner Jo' +
        'in'
      '  EMPLOYEE On PAYMENT_VOUCHER.EMPLOYEE_ID = EMPLOYEE.ID')
    Left = 608
    Top = 192
  end
  object dsPaymentVoucher: TDataSource
    DataSet = qryPaymentVoucher
    Left = 608
    Top = 240
  end
end
